<%@ page language="java" pageEncoding="utf-8"%>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>固定资产管理</title>

<SCRIPT language=JavaScript
	src="${pageContext.request.contextPath }/js/pinbi.js"></SCRIPT>
<link rel="stylesheet"
	href="${pageContext.request.contextPath }/layui/css/layui.css">
<script src="${pageContext.request.contextPath }/layui/layui.js"></script>
<META http-equiv=Content-Type content="text/html; charset=utf-8">
<META content="MSHTML 6.00.2900.3354" name=GENERATOR>
</head>

<BODY class="layui-layout-body">

	<div class="layui-layout layui-layout-admin">
		<div class="layui-header">
			<div class="layui-logo">固定资产管理</div>


			<!-- 		info部分 -->
			<ul class="layui-nav layui-layout-right">
				<li class="layui-nav-item"><a href="javascript:;">
						您好：${sessionScope.username } </a></li>
				<li class="layui-nav-item"><a name="/toupdatepwd"
					onclick="dispatch(this)" target="main">修改密码</a></li>
				<li class="layui-nav-item"><a onclick="clickFunction()"
					href="javascript:;">退出系统</a></li>
			</ul>
		</div>
		<!-- 左侧导航区域（可配合layui已有的垂直导航） -->
		<div class="layui-side layui-bg-black">
			<div class="layui-side-scroll">

				<ul class="layui-nav layui-nav-tree" lay-filter="test">
					<c:forEach items="${menus}" var="menu">
						<li class="layui-nav-item layui-nav-itemed"><a
							name="/${menu.url}" target="main" onclick="dispatch(this)">${menu.name}</a></li>
					</c:forEach>

				</ul>
			</div>
		</div>

		<!-- 内容主体区域 -->
		<div class="layui-body">
			<div>
				<iframe id="iframeMain" src="${pageContext.request.contextPath }/mainframe/default.jsp" style="width: 100%" ; height="99.4%";></iframe>
			</div>
		</div>
		
		
		<!-- 底部固定区域 -->
		<div class="layui-footer">© layui.com - 底部固定区域</div>
	</div>

</BODY>
<script>
	var $;
	layui.use([ 'element', 'layer' ], function() {
		var element = layui.element;
		var layer = layui.layer;
		$ = layui.$;
	});

	// 	退出系统确认
	function clickFunction() {
		layer.confirm('确定退出资产管理系统吗?', {
			btn : [ '确定', '取消' ]

		}, function() {
			window.location.href = "/";
		});
	}
	// 	切换ifream
	function dispatch(obj) {
		console.log(obj.name)
		$("#iframeMain").attr("src", obj.name);
		
	}
</script>
</html>
